﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using contactusform.dataaccess;


namespace contactusform.services
{
    public class ContactService
    {
        private ContactRepository _repository;

        /// <summary>
        /// Public Constructor
        /// </summary>
        public ContactService()
        {
            _repository = new ContactRepository();
        }

        /// <summary>
        /// Save a Contact Entity by consuming the top tier repository.
        /// </summary>
        /// <param name="contact">Entity to be saved</param>
        /// <returns></returns>
        public bool SaveContactInfo(Contact contact)
        {
            
            return _repository.Save(contact);
        }

    }

}
